View.vue
<template>
  <h1>分栏布局组件</h1>

  <el-row :gutter="10">
   <el-col :span="8">钟楚红</el-col>
   <el-col :span="8" style="border:1px solid red">张国荣</el-col>
   <el-col :span="8">周润发</el-col>
  </el-row>
  <hr>
  <el-row :gutter="10">
    <el-col :span="12"><img src="2024.png" style="width:100%"></el-col>
    <el-col :span="12"><img src="2024.png" style="width:100%"></el-col>
  </el-row>
  <hr>
  <el-row :gutter="10">
   <el-col :span="4"><img src="2024.png" style="width:100%"></el-col>
   <el-col :span="4"><img src="2024.png" style="width:100%"></el-col>
   <el-col :span="4"><img src="2024.png" style="width:100%"></el-col>
   <el-col :span="4"><img src="2024.png" style="width:100%"></el-col>
   <el-col :span="4"><img src="2024.png" style="width:100%"></el-col>
   <el-col :span="4"><img src="2024.png" style="width:100%"></el-col>
  </el-row>
  <hr>
  <el-row :gutter="10">
    <el-col :span="4"><img src="2024.png" style="width:100%"></el-col>
    <el-col :span="8"><img src="2024.png" style="width:100%"></el-col>
    <el-col :span="12"><img src="2024.png" style="width:100%"></el-col>
  </el-row>
  <hr>
  <el-row :gutter="10">
    <el-col :span="3" v-for="item in 8" style="border:1px solid red">{{item}}</el-col>
  </el-row>
  <hr>
  <h2>列偏移靠左</h2>
  <el-row :gutter="10">
   <el-col :span="20"><img src="2024.png" style="width:100%"></el-col>
  </el-row>
  <hr>
  <h2>列偏移靠右</h2>
  <el-row :gutter="10">
    <el-col :span="20" :offset="4"><img src="2024.png" style="width:100%"></el-col>
  </el-row>
  <hr>
  <h2>列偏移居中</h2>
  <el-row :gutter="10">
   <el-col :span="12" :offset="6"><img src="2024.png" style="width:100%"></el-col>
  </el-row>
  <hr>
  <h2>布局嵌套</h2>
  <el-row :gutter="10">
   <el-col :span="8" style="border:1px solid red">1</el-col>
   <el-col :span="16" style="border:1px solid red">
    <!-- 使用布局嵌套时，要把嵌套的元素看作一个完整的el-row(24份)来分配-->
     <el-row :gutter="5">
      <el-col :span="8" style="border:1px solid red">2-1</el-col>
      <el-col :span="8" style="border:1px solid green">2-2</el-col>
      <el-col :span="8" style="border:1px solid blue">2-3</el-col>
     </el-row>
   </el-col>
  </el-row>
</template>

<script setup>

</script>

<style scoped>

</style>